<?php

require_once 'banco.class.php';

abstract class base extends banco{
    
    //Propretiers
    public $table = "";
    public $fields_values = array();
    public $fieldspk = null;
    public $valuepk = null;
    public $extra_selects = "";
    
    //Metods
    public function addField($field=null, $value=null){
        if ($field!=NULL):
            $this->fields_values[$field]=$field;
        
        endif;
    } //addField
    
     public function delField($field=NULL){
         if (array_key_exists($field,  $this->fields_values)):
             unset($this->fields_values[$field]);
         endif;
     } //delFields
    
     public function setValues($field=NULL, $value=NULL){
         if ($field!=NULL && $value!=NULL):
            $this->fields_values[$field]=$value;
         endif;
     } //setValue
     
     public function getValue($field=NULL){
         if ($field!=NULL && array_key_exists($field, $this->fields_values)):
             return $this->fields_values[$field];
         else:
             return FALSE;
         endif;
     } // getValue
     
} //End class base

?>
